﻿using Abp.AutoMapper;
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.ComponentModel.DataAnnotations;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace MyABP.Tasks.Dtos
{
    [AutoMapTo(typeof(Task))] //定义单向映射
    public class CreateTaskInput
    {
        [DisplayName("用户名")]
        public int? AssignedPersonId { get; set; }

        [Required]
        [DisplayName("任务描述")]
        public string Description { get; set; }

        [Required]
        [DisplayName("任务标题")]
        public string Title { get; set; }
        [DisplayName("任务状态")]
        public TaskState State { get; set; }
        public override string ToString()
        {
            return string.Format("[CreateTaskInput > 用户 = {0}, 描述 = {1}]", AssignedPersonId, Description);
        }
    }
}
